// The Vue build version to load with the `import` command
// (runtime-only or standalone) has been set in webpack.base.conf with an alias.
import Vue from 'vue'
import App from './App'
import router from './router'
import Axios from "axios";
import shopNum from "@/store/modules/shopNum.js";

Vue.config.productionTip = false
Vue.prototype.$axios = Axios
    //1.引用Vuex
import Vuex from 'vuex'
//2.安装插件
Vue.use(Vuex)
    //3.创建store
const store = new Vuex.Store({
        modules: {
            shopNum
        }
    })
    //4.配置store中的数据/存/取


new Vue({
    el: '#app',
    router,
    //5.将store对象关联vue实例
    store,
    components: { App },
    template: '<App/>'
});